package controleur;

import ihm.ihmFenetre;

import java.awt.Cursor;
import java.awt.event.MouseEvent;
import java.awt.event.MouseListener;

import javax.swing.JLabel;

public class mouseLabel implements MouseListener {

	ihmFenetre fenetre;
	JLabel label;
	
	public mouseLabel(ihmFenetre pFenetre, JLabel pLabel) {
		fenetre = pFenetre;
		label = pLabel;
	}

	@Override
	public void mouseClicked(MouseEvent arg0) {
		fenetre.getCard().show(fenetre.getContentPane(), "panelCreationCompte");
	}

	@Override
	public void mouseEntered(MouseEvent arg0) {
		label.setCursor(new Cursor(Cursor.HAND_CURSOR));
	}

	@Override
	public void mouseExited(MouseEvent arg0) {
		label.setCursor(new Cursor(Cursor.DEFAULT_CURSOR));
	}

	@Override
	public void mousePressed(MouseEvent arg0) {
	}

	@Override
	public void mouseReleased(MouseEvent arg0) {
	}

}
